'''
Descripttion: 
version: 
Author: jinqian
Date: 2022-05-01 21:58:04
LastEditors: jinqian
LastEditTime: 2022-05-02 14:37:00
'''


class MyException(Exception):
    code: int = 1
    msg: str = 'fail'


class UserNotFoundException(MyException):
    code = 10001
    msg = '用户未找到'


class PasswordNotMatchException(MyException):
    code = 10002
    msg = '密码错误'


class RemoteNodeNotSetDockerException(MyException):
    code = 10003
    msg = '远程节点未设置Docker远程访问'


class CurrentHostNotSetSwarmException(MyException):
    code = 10004
    msg = '当前节点未启动Swarm'


class JoinSwarmErrorException(MyException):
    code = 10005
    msg = '加入Swarm失败'


class GetTokenErrorException(MyException):
    code = 10006
    msg = '获取token失败'


class DockerisNotStartException(MyException):
    code = 10007
    msg = 'Docker未启动'


class StorageIsNotBuildException(MyException):
    code = 10008
    msg = '存储集群未建立'


class UnknowException(MyException):
    code = 20008
    msg = '未知错误，请联系管理人员'
